object fCadCompra: TfCadCompra
  Left = 383
  Top = 128
  BorderIcons = [biSystemMenu]
  BorderStyle = bsSingle
  Caption = 'Lancamento de Compra'
  ClientHeight = 490
  ClientWidth = 616
  Color = clBtnFace
  Font.Charset = DEFAULT_CHARSET
  Font.Color = clWindowText
  Font.Height = -11
  Font.Name = 'MS Sans Serif'
  Font.Style = []
  KeyPreview = True
  OldCreateOrder = False
  Position = poMainFormCenter
  OnKeyPress = FormKeyPress
  OnShow = FormShow
  PixelsPerInch = 96
  TextHeight = 13
  object PageControl1: TPageControl
    Left = -5
    Top = -25
    Width = 627
    Height = 524
    ActivePage = TabSheet1
    TabOrder = 0
    object TabSheet1: TTabSheet
      Caption = 'TabSheet1'
      object Label1: TLabel
        Left = 8
        Top = 48
        Width = 77
        Height = 13
        Caption = 'Data da Compra'
      end
      object Label2: TLabel
        Left = 8
        Top = 8
        Width = 38
        Height = 13
        Caption = 'Nota N'#186
      end
      object SpeedButton1: TSpeedButton
        Left = 460
        Top = 46
        Width = 153
        Height = 43
        Caption = 'Lan'#231'ar Produtos'
        OnClick = SpeedButton1Click
      end
      object Label7: TLabel
        Left = 96
        Top = 334
        Width = 63
        Height = 13
        Caption = 'Desconto (%)'
      end
      object Label8: TLabel
        Left = 96
        Top = 374
        Width = 69
        Height = 13
        Caption = 'Desconto (R$)'
      end
      object Label9: TLabel
        Left = 8
        Top = 334
        Width = 60
        Height = 13
        Caption = 'Adicional (%)'
      end
      object Label10: TLabel
        Left = 8
        Top = 374
        Width = 66
        Height = 13
        Caption = 'Adicional (R$)'
      end
      object SpeedButton2: TSpeedButton
        Left = 457
        Top = 432
        Width = 153
        Height = 44
        Caption = 'Financeiro'
        OnClick = SpeedButton2Click
      end
      object SpeedButton3: TSpeedButton
        Left = 5
        Top = 430
        Width = 136
        Height = 25
        Caption = 'Cadastrar Fornecedor'
        Flat = True
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
        OnClick = SpeedButton3Click
      end
      object Label4: TLabel
        Left = 112
        Top = 48
        Width = 78
        Height = 13
        Caption = 'Data de Entrada'
      end
      object Label13: TLabel
        Left = 90
        Top = 8
        Width = 54
        Height = 13
        Caption = 'Fornecedor'
      end
      object SpeedButton5: TSpeedButton
        Left = 589
        Top = 21
        Width = 23
        Height = 25
        Flat = True
        Glyph.Data = {
          2E060000424D2E06000000000000360400002800000015000000150000000100
          080000000000F8010000120B0000120B0000000100005D00000000000000DFDF
          E800E9E90C008D8D8D0092924E00FFFF720070702A00BEBDBD00CECE14003737
          270062626900F4F41E001D1D1D00A8A81B00F6F6FB00FFFFE20099999900FFFF
          B9005A5A5200D9D929009C9C6200FFFFEE007C7B6900C5C5D40042423900FFFF
          0000FFFFAA00A5A59E00A9A93800D7D7130095959200FFFF3B00807F39000908
          0800F2F2F200D8D8D800FFFF990077775D00E1E14700949480004F4F4F00B4B4
          A400CCCCCC00BBBB22008B8A6900757575002A2A37009D9D4300F9F90900FFFF
          FF003D3B3B00FFFF8F009090AB00FFFF1C00F8F8F8008585490085859800CFCF
          D9000E0E0E00E4E4E400E0E0E000ABAB1E0033333300FFFF830064647E002929
          2700FFFFC6007A7A7A00D2D22200FFFF2D00C2C2C200A5A53F00AFAFAF00ECEC
          06009B9BA600DDDD2D00C8C81D00FCFC060000000500CECEDE0095955400FFFF
          2300A4A3A300F0F0F500E2E2EB0076763300D1D1150024232800A6A52300FFFF
          BD005D5C5C00D6D6E000F4F41000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000313131313131
          3131313131313131313131313131310000003131313131313131313131313131
          3131313131313100000031313131313131313131313131313131313123033100
          00003131313131313131313131313131313131073E2152000000313131313131
          3131313131313131313643210032520000003131313131313131313131313131
          2A3200002D223100000031313131310E530E3131313131103A000C4831313100
          00003131314627502F141B54313B5A0000283C31313131000000313103504B19
          194D08043841002103313131313131000000314A4759511919191930064E3E2A
          31313131313131000000012033051919191919195C1222313131313131313100
          0000402B4245191919191919192F0E313131313131313100000057130F351919
          19191919193D3931313131313131310000002E44153F19191919191919585B31
          31313131313131000000340D243135191919191919370E313131313131313100
          000036250B1A1F19191919194C4A31313131313131313100000031395549111F
          1919195616363131313131313131310000003131172C2926021D1C1E53313131
          313131313131310000003131310E1B18090A3931313131313131313131313100
          0000313131313131313131313131313131313131313131000000313131313131
          313131313131313131313131313131000000}
        OnClick = SpeedButton5Click
      end
      object SpeedButton4: TSpeedButton
        Left = 5
        Top = 451
        Width = 136
        Height = 25
        Caption = 'Cadastrar Produto'
        Flat = True
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
        OnClick = SpeedButton4Click
      end
      object Label5: TLabel
        Left = 344
        Top = 354
        Width = 112
        Height = 15
        Caption = 'Total dos Produtos'
        Font.Charset = ANSI_CHARSET
        Font.Color = clWindowText
        Font.Height = -13
        Font.Name = 'Cambria'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label6: TLabel
        Left = 367
        Top = 386
        Width = 88
        Height = 15
        Caption = 'Total da Venda'
        Font.Charset = ANSI_CHARSET
        Font.Color = clWindowText
        Font.Height = -13
        Font.Name = 'Cambria'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object lbTotalProduto: TDBText
        Left = 487
        Top = 347
        Width = 115
        Height = 20
        Alignment = taRightJustify
        DataField = 'SUB_TOTAL'
        DataSource = DataSource1
        Font.Charset = ANSI_CHARSET
        Font.Color = clWindowText
        Font.Height = -19
        Font.Name = 'Cambria'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object lbTotalNota: TDBText
        Left = 483
        Top = 374
        Width = 119
        Height = 32
        Alignment = taRightJustify
        DataField = 'VALOR_TOTAL'
        DataSource = DataSource1
        Font.Charset = ANSI_CHARSET
        Font.Color = clBlue
        Font.Height = -27
        Font.Name = 'Cambria'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object dbNumNota: TDBEdit
        Left = 8
        Top = 24
        Width = 73
        Height = 21
        DataField = 'NUM_NOTA'
        DataSource = DataSource1
        TabOrder = 0
      end
      object DBGrid2: TDBGrid
        Left = 8
        Top = 95
        Width = 605
        Height = 232
        DataSource = dsItens
        Options = [dgTitles, dgIndicator, dgColLines, dgRowLines, dgTabs, dgRowSelect, dgConfirmDelete, dgCancelOnExit]
        TabOrder = 5
        TitleFont.Charset = DEFAULT_CHARSET
        TitleFont.Color = clWindowText
        TitleFont.Height = -11
        TitleFont.Name = 'MS Sans Serif'
        TitleFont.Style = []
        OnDrawColumnCell = DBGrid2DrawColumnCell
        OnDblClick = DBGrid2DblClick
        OnKeyDown = DBGrid2KeyDown
        Columns = <
          item
            Expanded = False
            FieldName = 'PRODUTO_FK'
            Title.Caption = 'Codigo'
            Width = 51
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'DESCRICAO'
            Title.Caption = 'Produto'
            Width = 264
            Visible = True
          end
          item
            Alignment = taCenter
            Expanded = False
            FieldName = 'QUANTIDADE'
            Title.Alignment = taCenter
            Title.Caption = 'Qtde'
            Width = 55
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'VALOR_UNIT'
            Title.Alignment = taRightJustify
            Title.Caption = 'Valor Unit'#225'rio'
            Width = 95
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'VALOR_TOTAL'
            Title.Alignment = taRightJustify
            Title.Caption = 'Valor Total'
            Width = 97
            Visible = True
          end>
      end
      object dbData: TDBDateEdit
        Left = 8
        Top = 64
        Width = 97
        Height = 21
        DataField = 'DATA_COMPRA'
        DataSource = DataSource1
        NumGlyphs = 2
        TabOrder = 3
        OnExit = dbDataExit
      end
      object dbAdicPerc: TRxCalcEdit
        Left = 8
        Top = 350
        Width = 81
        Height = 21
        AutoSize = False
        DisplayFormat = '##,###,#0.00'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clBlue
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        NumGlyphs = 2
        ParentFont = False
        TabOrder = 6
        OnExit = dbAdicPercExit
      end
      object dbAdicValor: TRxCalcEdit
        Left = 8
        Top = 390
        Width = 81
        Height = 21
        AutoSize = False
        DisplayFormat = '##,###,#0.00'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clBlue
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        NumGlyphs = 2
        ParentFont = False
        TabOrder = 7
        OnExit = dbAdicValorExit
      end
      object dbDescPerc: TRxCalcEdit
        Left = 96
        Top = 350
        Width = 81
        Height = 21
        AutoSize = False
        DisplayFormat = '##,###,#0.00'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clMaroon
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        NumGlyphs = 2
        ParentFont = False
        TabOrder = 8
        OnExit = dbDescPercExit
      end
      object dbDescValor: TRxCalcEdit
        Left = 96
        Top = 390
        Width = 81
        Height = 21
        AutoSize = False
        DisplayFormat = '##,###,#0.00'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clMaroon
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        NumGlyphs = 2
        ParentFont = False
        TabOrder = 9
        OnExit = dbDescValorExit
      end
      object dbDataEntrada: TDBDateEdit
        Left = 112
        Top = 64
        Width = 97
        Height = 21
        DataField = 'DATA_ENTRADA'
        DataSource = DataSource1
        NumGlyphs = 2
        TabOrder = 4
        OnExit = dbDataEntradaExit
        OnKeyPress = dbDataEntradaKeyPress
      end
      object dbFornecedor: TDBEdit
        Left = 90
        Top = 24
        Width = 66
        Height = 21
        DataField = 'FORNECEDOR_FK'
        DataSource = DataSource1
        TabOrder = 1
        OnExit = dbFornecedorExit
        OnKeyDown = dbFornecedorKeyDown
      end
      object Edit1: TEdit
        Left = 160
        Top = 24
        Width = 427
        Height = 21
        Enabled = False
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
        TabOrder = 2
      end
      object GroupBox1: TGroupBox
        Left = -8
        Top = 414
        Width = 645
        Height = 7
        TabOrder = 10
      end
    end
    object TabSheet2: TTabSheet
      Caption = 'TabSheet2'
      ImageIndex = 1
      object Bevel1: TBevel
        Left = 6
        Top = 6
        Width = 605
        Height = 55
      end
      object Label12: TLabel
        Left = 15
        Top = 40
        Width = 54
        Height = 13
        Caption = 'Fornecedor'
      end
      object Label14: TLabel
        Left = 336
        Top = 16
        Width = 38
        Height = 13
        Caption = 'Nota N'#186
      end
      object Label15: TLabel
        Left = 45
        Top = 16
        Width = 23
        Height = 13
        Caption = 'Data'
      end
      object Label16: TLabel
        Left = 389
        Top = 12
        Width = 60
        Height = 19
        Caption = 'Label16'
        Font.Charset = ANSI_CHARSET
        Font.Color = clBlue
        Font.Height = -16
        Font.Name = 'Arial'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label17: TLabel
        Left = 80
        Top = 16
        Width = 28
        Height = 13
        Caption = 'Data'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label18: TLabel
        Left = 80
        Top = 40
        Width = 40
        Height = 13
        Caption = 'Cliente'
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label21: TLabel
        Left = 283
        Top = 38
        Width = 80
        Height = 19
        Caption = 'Valor Total'
        Font.Charset = ANSI_CHARSET
        Font.Color = clWindowText
        Font.Height = -16
        Font.Name = 'Arial'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label20: TLabel
        Left = 390
        Top = 35
        Width = 38
        Height = 22
        Caption = '0,00'
        Font.Charset = ANSI_CHARSET
        Font.Color = clBlue
        Font.Height = -19
        Font.Name = 'Arial'
        Font.Style = [fsBold]
        ParentFont = False
      end
      object Label3: TLabel
        Left = 15
        Top = 80
        Width = 117
        Height = 13
        Caption = 'Condicao de Pagamento'
      end
      object SpeedButton6: TSpeedButton
        Left = 583
        Top = 93
        Width = 23
        Height = 25
        Flat = True
        Glyph.Data = {
          2E060000424D2E06000000000000360400002800000015000000150000000100
          080000000000F8010000120B0000120B0000000100005D00000000000000DFDF
          E800E9E90C008D8D8D0092924E00FFFF720070702A00BEBDBD00CECE14003737
          270062626900F4F41E001D1D1D00A8A81B00F6F6FB00FFFFE20099999900FFFF
          B9005A5A5200D9D929009C9C6200FFFFEE007C7B6900C5C5D40042423900FFFF
          0000FFFFAA00A5A59E00A9A93800D7D7130095959200FFFF3B00807F39000908
          0800F2F2F200D8D8D800FFFF990077775D00E1E14700949480004F4F4F00B4B4
          A400CCCCCC00BBBB22008B8A6900757575002A2A37009D9D4300F9F90900FFFF
          FF003D3B3B00FFFF8F009090AB00FFFF1C00F8F8F8008585490085859800CFCF
          D9000E0E0E00E4E4E400E0E0E000ABAB1E0033333300FFFF830064647E002929
          2700FFFFC6007A7A7A00D2D22200FFFF2D00C2C2C200A5A53F00AFAFAF00ECEC
          06009B9BA600DDDD2D00C8C81D00FCFC060000000500CECEDE0095955400FFFF
          2300A4A3A300F0F0F500E2E2EB0076763300D1D1150024232800A6A52300FFFF
          BD005D5C5C00D6D6E000F4F41000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000000000000000
          0000000000000000000000000000000000000000000000000000313131313131
          3131313131313131313131313131310000003131313131313131313131313131
          3131313131313100000031313131313131313131313131313131313123033100
          00003131313131313131313131313131313131073E2152000000313131313131
          3131313131313131313643210032520000003131313131313131313131313131
          2A3200002D223100000031313131310E530E3131313131103A000C4831313100
          00003131314627502F141B54313B5A0000283C31313131000000313103504B19
          194D08043841002103313131313131000000314A4759511919191930064E3E2A
          31313131313131000000012033051919191919195C1222313131313131313100
          0000402B4245191919191919192F0E313131313131313100000057130F351919
          19191919193D3931313131313131310000002E44153F19191919191919585B31
          31313131313131000000340D243135191919191919370E313131313131313100
          000036250B1A1F19191919194C4A31313131313131313100000031395549111F
          1919195616363131313131313131310000003131172C2926021D1C1E53313131
          313131313131310000003131310E1B18090A3931313131313131313131313100
          0000313131313131313131313131313131313131313131000000313131313131
          313131313131313131313131313131000000}
        OnClick = SpeedButton6Click
      end
      object SpeedButton7: TSpeedButton
        Left = 5
        Top = 452
        Width = 136
        Height = 25
        Caption = 'Cadastrar Cond. Pagto'
        Flat = True
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
        OnClick = SpeedButton7Click
      end
      object BitBtn1: TBitBtn
        Left = 13
        Top = 391
        Width = 148
        Height = 42
        Caption = 'Voltar'
        TabOrder = 1
        OnClick = BitBtn1Click
      end
      object btnFaturar: TBitBtn
        Left = 465
        Top = 390
        Width = 143
        Height = 43
        Caption = 'Faturar'
        TabOrder = 2
        OnClick = btnFaturarClick
      end
      object grid: TStringGrid
        Left = 15
        Top = 123
        Width = 591
        Height = 223
        ColCount = 4
        DefaultRowHeight = 19
        FixedCols = 0
        RowCount = 2
        Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goRangeSelect, goEditing, goRowSelect]
        TabOrder = 3
        ColWidths = (
          52
          89
          139
          87)
      end
      object dbCondicao: TDBEdit
        Left = 15
        Top = 96
        Width = 63
        Height = 21
        DataField = 'CONDICAO_PGTO_FK'
        DataSource = DataSource1
        TabOrder = 0
        OnExit = dbCondicaoExit
        OnKeyDown = dbCondicaoKeyDown
      end
      object Edit2: TEdit
        Left = 82
        Top = 96
        Width = 498
        Height = 21
        Enabled = False
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -11
        Font.Name = 'MS Sans Serif'
        Font.Style = [fsBold]
        ParentFont = False
        TabOrder = 4
      end
      object GroupBox2: TGroupBox
        Left = -14
        Top = 363
        Width = 640
        Height = 7
        TabOrder = 5
      end
    end
  end
  object DataSource1: TDataSource
    DataSet = dm.qryCompra
    Left = 119
    Top = 151
  end
  object DataSource2: TDataSource
    Left = 231
    Top = 159
  end
  object qryItens: TIBOQuery
    Params = <
      item
        DataType = ftUnknown
        Name = 'cod_compra'
        ParamType = ptUnknown
      end>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    SQL.Strings = (
      'select compra_itens.*,PRODUTO.descricao FROM compra_itens'
      'INNER JOIN produto ON (compra_ITENS.produto_fk = PRODUTO.codigo)'
      'WHERE compra_itens.compra_fk = :cod_compra'
      'order by compra_itens.codigo')
    FieldOptions = []
    Left = 176
    Top = 216
    object qryItensCODIGO: TIntegerField
      FieldName = 'CODIGO'
      Required = True
    end
    object qryItensPRODUTO_FK: TIntegerField
      FieldName = 'PRODUTO_FK'
    end
    object qryItensQUANTIDADE: TBCDField
      FieldName = 'QUANTIDADE'
      Size = 2
    end
    object qryItensVALOR_UNIT: TBCDField
      FieldName = 'VALOR_UNIT'
      DisplayFormat = '##,###,#0.00'
      Size = 2
    end
    object qryItensVALOR_TOTAL: TBCDField
      FieldName = 'VALOR_TOTAL'
      DisplayFormat = '##,###,#0.00'
      Size = 2
    end
    object qryItensCOMPRA_FK: TIntegerField
      FieldName = 'COMPRA_FK'
    end
    object qryItensDESCRICAO: TStringField
      FieldName = 'DESCRICAO'
      Size = 100
    end
  end
  object dsItens: TDataSource
    DataSet = qryItens
    Left = 327
    Top = 167
  end
  object atualizaTotal: TIBOQuery
    Params = <
      item
        DataType = ftInteger
        Name = 'cod_venda'
        ParamType = ptInput
      end>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    SQL.Strings = (
      
        'select sum(venda_itens.valor_total) as total_prod FROM venda_ite' +
        'ns'
      'WHERE venda_itens.venda_fk = :cod_venda')
    FieldOptions = []
    Left = 112
    Top = 208
    object atualizaTotalTOTAL_PROD: TBCDField
      FieldName = 'TOTAL_PROD'
      ReadOnly = True
      Size = 2
    end
  end
  object atualizaTotalVenda: TIBOQuery
    Params = <>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    FieldOptions = []
    Left = 32
    Top = 192
  end
  object deletaItem: TIBOQuery
    Params = <
      item
        DataType = ftUnknown
        Name = 'COD_ITEM'
        ParamType = ptUnknown
      end>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    SQL.Strings = (
      'delete from compra_itens'
      'where compra_itens.codigo = :COD_ITEM')
    FieldOptions = []
    Left = 264
    Top = 224
  end
  object resumo: TIBOQuery
    Params = <
      item
        DataType = ftInteger
        Name = 'COMPRA'
        ParamType = ptInput
      end>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    SQL.Strings = (
      'select pessoa.nome as fornecedor from compra'
      'inner join pessoa on pessoa.codigo = compra.fornecedor_fk'
      'where compra.codigo = :COMPRA')
    FieldOptions = []
    Left = 392
    Top = 192
    object resumoFORNECEDOR: TStringField
      FieldName = 'FORNECEDOR'
      Size = 100
    end
  end
  object dsCondPgto: TDataSource
    DataSet = dm.qryCondPgto
    Left = 208
    Top = 288
  end
  object GeraCodigo: TIBOQuery
    Params = <>
    DatabaseName = 'C:\Delphi7\Integrado\Dados\BANCO.GDB'
    IB_Connection = dm.base
    RecordCountAccurate = True
    SQL.Strings = (
      'select GEN_ID(GEN_COMPRA_ID,1) PK FROM RDB$DATABASE')
    FieldOptions = []
    Left = 128
    Top = 249
    object GeraCodigoPK: TLargeintField
      FieldName = 'PK'
      ReadOnly = True
      Required = True
    end
  end
end
